const Koa = require('koa')
const app = new Koa();
const bodyParser = require('koa-bodyparser')

const userRouter = require('./router/user')
const listRouter = require('./router/list')

app.use(bodyParser())

app.use(userRouter.routes()).use(userRouter.allowedMethods())
app.use(listRouter.routes()).use(listRouter.allowedMethods())

app.listen(7001, () => {
  console.log('服务器启动了！！！')
})